
import { _decorator, Component } from 'cc';
import { Event_Enum } from '../Enum';
import EventManager from '../Runtime/EventManager';
const { ccclass, property } = _decorator;


@ccclass('RenderManager')
export abstract class RenderManager extends Component {

    protected start(): void {
        this.render();
        EventManager.Instance.on(Event_Enum.Render, this.render, this);
    }

    protected onDestroy(): void {
        EventManager.Instance.off(Event_Enum.Render, this.render, this);
    }

    abstract render()
}
